<?php
header('Content-type:text/html; charset=utf-8');
require_once( 'utils.php' );
require_once( 'device-manager.php' );
require_once( 'rent-manager.php' );
require_once( 'page-builder.php' );

//Init device manager for in and out counts
$deviceManager = new DeviceManager();

//Include header HTML
require_once( 'header.php' );

?>

<h1><?php Utils::getPageTitle(); ?></h1>

<?php

echo '<div class="device-row device-row-shadow" id="add-device" style="display:none;">';
echo '<img src="http://www.hk.tlu.ee/~kuli/hk/qr.php?sisu=new-device" class="qr-id" style="width:100px; height: 100px; z-index: 4" />';
echo '<div class="device-data add" style="">';
echo '<form action="service.php" method="post" enctype="multipart/form-data">
	<input type="hidden" name="service_action" value="1" />';
echo '<input type="text" name="device_model" autofocus="autofocus" placeholder="Mudel" required="required" style="width: 280px; font-weight: bold;"/>';	
echo '<textarea rows="1" placeholder="Seadme / komplekti lühikirjeldus" cols="44" class="device_desc_edit" name="device_description"></textarea>';
echo '<br /><b>S/N:</b> <input type="text" maxlength="250" name="device_serial" required="required" autocomplete="off" placeholder="Seerianumber / IMEI" style="width: 250px" />';
echo '<br /><b>Väärtus:</b> <input type="text" maxlength="10" name="device_value" autocomplete="off" placeholder="Väärtus €" style="width: 226px"/>';

echo '<br /><b>Pilt:</b> <input type="file" style="border: 0px" name="device_image_uploaded" />';

echo '<br /><button style="margin-left: 210px" type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" role="button" aria-disabled="false">
		<span id="device-btn-text" class="ui-button-text">Lisa</span>
	</button>';
echo '</form>';
echo '</div></div>';

PageBuilder::getContent();

require_once( 'footer.php' );
?>